<!-- loading组件 -->
<template>
  <div v-if="props.isLoading" class="container">
    <img :src="loading_img" alt="" srcset="" />
  </div>
</template>

<script setup lang="ts">
import { defineProps } from "vue";
import loading_img from "./loading.gif";
const props = defineProps({
  isLoading: {
    type: Boolean,
    required: true,
    default: false,
  },
});
</script>

<style lang="less" scoped>
.container {
  display: flex;
  justify-content: center;
  align-items: center;
}
</style>
